package com.yun.csv2db.entity.enums;

public enum SexEnum {
    Female(0), Male(1), Unknown(2);


    private int type;

    private SexEnum(int t) {
        this.type = t;
    }

    public static SexEnum getEnumFromString(String string) {
        if (string != null) {
            try {
                return Enum.valueOf(SexEnum.class, string.trim());
            } catch (IllegalArgumentException ex) {

            }
        }
        return null;
    }

    public int getType() {
        return type;
    }
}
